const userController = require('./controller/user');
const sysuserController = require('./controller/sysuser');
const stationController = require('./controller/station');

module.exports = (router) => {
  router.prefix('/api');
  router
    .get('/profile', userController.profile)
    .get('/mockdata', userController.mockdata)
    .post('/userFilter', userController.userFilter)
    .post('/yearFilter', userController.yearFilter)
    .post('/login', userController.login)
    .post('/register', userController.register)
    .post('/logout', userController.logout)
    .post('/syslogin', sysuserController.login)
    .post('/sysuserFilter', sysuserController.userFilter)
    .post('/sysregister', sysuserController.register)
    .post('/resetPasswd', sysuserController.resetPasswd)
    .post('/setUserInfo', sysuserController.setUserInfo)

    .post('/getOuName', stationController.getOuName)
    .post('/getStaName', stationController.getStaName)
    .post('/getStaData', stationController.StationDataFilter)
    .post('/updateStaData', stationController.updateStaData)
    .post('/delStaData', stationController.delStaData)
    .post('/creatStaData', stationController.creatStaData)
};
